Skip to content

feat(graph): add read-only Godot resource audit (orphan/dangling/impact)#82

Merged
sunerpy merged 1 commit into
mainfrom
feat/godot-resource-audit
Jun 27, 2026
Merged

feat(graph): add read-only Godot resource audit (orphan/dangling/impact)#82
sunerpy merged 1 commit into
mainfrom
feat/godot-resource-audit

Conversation

@sunerpy

@sunerpy sunerpy commented Jun 27, 2026

Copy link
Copy Markdown
Owner

Summary

  • Adds a separate, read-only codegraph audit subcommand for Godot projects:
    • --orphans.tres/.tscn resources nothing references
    • --dangling — path references whose target is missing on disk
    • --impact <path> — reverse-dependency list for a changed resource/script
  • Computed from the existing graph + on-disk existence checks. Adds no extraction, no node/edge writes — golden byte-neutral.
  • A separate subcommand (NOT a check flag), so plain check output stays byte-identical (locked by a committed snapshot test).

Design note

Godot .tres/.tscn/project.godot files carry no file: graph node; their references live in unresolved_refs. The audit therefore keys on resource paths, not incoming graph edges. Dangling exclusion precedence: .godot//addons/ prefix → godot:dynamic: sentinels → on-disk existence.

This is a downstream-only feature — no analogue in upstream colby (verified against v1.1.1 HEAD).

Verification

  • make ci green locally (fmt + clippy + test + guardrail)
  • git diff --stat reference/ empty (golden-neutral; read-only)
  • cargo test -p codegraph-bench 4/4 (golden oracle)
  • New tests: graph-level godot_resource_audit.rs (7 cases) + CLI e2e audit.rs (orphan/dangling JSON + check byte-identical baseline)

Adds a separate, read-only `audit` CLI subcommand reporting orphan Godot
resources, dangling path references, and reverse-dependency impact. Computed
from the existing graph plus on-disk existence checks — no extraction, no new
node/edge writes — so it is golden-neutral and leaves `check` byte-identical.

The .tres/.tscn/project.godot files carry no `file:` graph node and their
references stay in `unresolved_refs`, so the audit keys on resource PATHS, not
incoming graph edges.
@sunerpy sunerpy merged commit 7f80b0f into main Jun 27, 2026
4 checks passed
@sunerpy sunerpy deleted the feat/godot-resource-audit branch June 27, 2026 07:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant